#ifndef GLOBALS_H
#define GLOBALS_H

#include <map>
#include <vector>
#include "constants.h"
#include "tile.h"
#include "myplayer.h"
#include "player.h"
#include "npc.h"
#include "log.h"
#include "login.h"
#include "camera.h"
#include "minimap.h"
#include "input.h"
#include "config.h"
#include "network.h"
#include "RakPeerInterface.h"
#include "SDL/SDL.h"
#include "SDL/SDL_mixer.h"
#include "SDL/SDL_ttf.h"

#define LOGFILE "log.txt"

extern bool debug;
extern bool loop;

extern SDL_Surface *screen;
extern SDL_Surface *imgMyPlayer;
extern SDL_Surface *imgPlayer;
extern SDL_Surface *imgFlag;
extern SDL_Surface *imgNpc;
extern SDL_Surface *tileSheet;

extern SDL_Surface *mmMyPlayer;
extern SDL_Surface *mmPlayer;
extern SDL_Surface *mmNpc;

// Debugging
extern SDL_Surface *position_surface;
extern SDL_Surface *players;
extern SDL_Surface *currfps;

extern Mix_Music *music;
extern TTF_Font *font;

extern SDL_Color textColor;

extern Tile *tiles[MAP_HEIGHT][MAP_WIDTH];

extern Log output;
extern Config cfg;
extern Login login;
extern myPlayer P;
extern std::map<RakNet::RakNetGUID, Player*> Players;
extern std::map<int, Npc*> Npcs;
extern Camera cam;
extern Minimap mm;
extern Input in;
extern Network net;

enum Directions
{
    DIR_RIGHTUP,
    DIR_RIGHT,
    DIR_RIGHTDOWN,
    DIR_DOWN,
    DIR_LEFTDOWN,
    DIR_LEFT,
    DIR_LEFTUP,
    DIR_UP,
};

#endif // GLOBALS_H
